package com.hospital.xiaochengxiu.wu.service.impl;

import com.hospital.xiaochengxiu.wu.dao.CardLoginMapper;
import com.hospital.xiaochengxiu.wu.entity.CardLogin;
import com.hospital.xiaochengxiu.wu.entity.CardName;
import com.hospital.xiaochengxiu.wu.service.CardLoginService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CardLoginServiceImpl implements CardLoginService {
    @Autowired
    CardLoginMapper cardLoginMapper;
    @Override
    public boolean InsCard(CardLogin cardLogin) {
        return cardLoginMapper.InsCard(cardLogin)==1;
    }

    @Override
    public CardName FindName(String phone) {
        return cardLoginMapper.FindName(phone);
    }

    @Override
    public CardName FindNameCard(String name, String idCard) {
        CardName cardName = cardLoginMapper.FindNameCard(name, idCard);
        return cardName;
    }
}
